import time as _time
import torch as _torch
# from src.networks import ExpTripletNetwork as _use_net

_name = str(__name__)
_time = _time.strftime('%m-%d %H:%M:%S', _time.localtime())


# USE_NET = _use_net

IMAGE_EMBEDDER = 'inception v3'

# Dataset
DATASET_PROC_METHOD_TRAIN = 'Rescale'
DATASET_PROC_METHOD_VAL = 'Rescale'


#
# Category
# CATEGORY_CLASS_FILE = 'category_class_coarse.txt'
MAX_CATEGORY_NUM = 100  #Not USE

# NetWork相关
IMAGE_EMBED_SIZE = 512


# WEIGHT
WEIGHT_IMAGE_TEXT = 1.0
WEIGHT_SPARSE_SOFTMAX = 10.0
WEIGHT_L1_LOSS = 000.1

# Word Embdding 相关
USE_PRETRAINED_WORD_EMBEDDING = True
WORD_EMBED_SIZE = 300  # 这个是和之前word2vec保持一致的
MAX_VOCAB_SIZE = 2500
OUTFIT_NAME_PAD_NUM = 10 # 保留那么多单词
###


# TRAIN：训练时选项
NUM_EPOCH = 20
LEARNING_RATE = 0.0001
LEARNING_RATE_DECAY = 0.95
BATCH_SIZE = 8
SAVE_EVERY_STEPS = 10000
SAVE_EVERY_EPOCHS = 1

# VAL：测试时选项
VAL_WHILE_TRAIN = True
VAL_FASHION_COMP_FILE = "fashion_compatibility_small.txt"
VAL_FITB_FILE = "fill_in_blank_test_small.json"
VAL_BATCH_SIZE = 8
VAL_EVERY_STEPS = 1000
VAL_EVERY_EPOCHS = 1
VAL_START_EPOCH = 1

# auto
device = _torch.device('cuda:0' if _torch.cuda.is_available() else 'cpu')
TRAIN_DIR = 'runs/%s/' % _name + _time
VAL_DIR = 'runs/%s/' % _name + _time
MODEL_NAME = '%s' % _name

